package com.hm.shopping.domain;

import java.util.ArrayList;
import java.util.List;

import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.data.mongodb.core.mapping.Field;

import com.hm.shopping.auto.su.BaseDomain;
import com.hm.shopping.auto.su.R;
import com.hm.shopping.def.OrderStateEnum;

import lombok.Getter;
import lombok.Setter;

/**
 * @author shishun.wang
 * @date 2018年2月9日 下午4:11:37
 * @version 1.0
 * @describe 购物车购买商品快照
 */
@Setter
@Getter
@Document(collection = R.Database.prefix + "BUY_GOODS_SNAPSHOT")
public class BuyGoodsOrderSnapshotDomain extends BaseDomain{

	private static final long serialVersionUID = 8741776505793067329L;

	/**
	 * 订单号
	 */
	@Field(value = "order_id")
	private String orderId;

	/**
	 * 购买用户
	 */
	@Field(value = "buyer_id")
	private String buyerId;
	
	/**
	 * 订单支付状态
	 */
	@Field(value = "order_pay_state")
	private OrderStateEnum orderPayState;

	/**
	 * 支付金额
	 */
	@Field(value = "pay_amount")
	private long payAmount;
	
	/**
	 * 商品快照集合
	 */
	@Field(value = "snapshot_details")
	private List<GoodsIntroductionSnapshotDetailDomain> snapshotDetails = new ArrayList<GoodsIntroductionSnapshotDetailDomain>();
}
